﻿using PARK.Common.Const;
using SqlSugar;
using System;

namespace PARK.Consumer.Entity
{
    /// <summary>
    /// 消费调整记录
    /// </summary>
    [SugarTable("consum_adjust")]
    [Tenant(ClaimConst.TENANT_ID)]
    public class ConsumAdjustEntity
    {
        /// <summary>
        /// 
        /// </summary>
        [SugarColumn(ColumnName = "Id", IsPrimaryKey = true)]
        public string Id { get; set; }
        
        /// <summary>
        /// 消费机Id
        /// </summary>
        [SugarColumn(ColumnName = "MachineId")]        
        public string MachineId { get; set; }
        
        /// <summary>
        /// 消费机编号
        /// </summary>
        [SugarColumn(ColumnName = "MachineNo")]        
        public string MachineNo { get; set; }
        
        /// <summary>
        /// 消费机名称
        /// </summary>
        [SugarColumn(ColumnName = "MachineName")]        
        public string MachineName { get; set; }
        
        /// <summary>
        /// 商户Id
        /// </summary>
        [SugarColumn(ColumnName = "MerchantId")]        
        public string MerchantId { get; set; }
        
        /// <summary>
        /// 商户编号
        /// </summary>
        [SugarColumn(ColumnName = "MerchantCode")]        
        public string MerchantCode { get; set; }
        
        /// <summary>
        /// 商户名称
        /// </summary>
        [SugarColumn(ColumnName = "MerchantName")]        
        public string MerchantName { get; set; }
        
        /// <summary>
        /// 消费卡号
        /// </summary>
        [SugarColumn(ColumnName = "CardNo")]        
        public string CardNo { get; set; }
        
        /// <summary>
        /// 扣费方式 1刷卡  2刷码
        /// </summary>
        [SugarColumn(ColumnName = "ConsumKind")]        
        public int? ConsumKind { get; set; }
        
        /// <summary>
        /// 刷码,码内容
        /// </summary>
        [SugarColumn(ColumnName = "ConsumQRcode")]        
        public string ConsumQRcode { get; set; }
        
        /// <summary>
        /// 用户Id
        /// </summary>
        [SugarColumn(ColumnName = "EmployeeId")]        
        public string EmployeeId { get; set; }
        
        /// <summary>
        /// 工号
        /// </summary>
        [SugarColumn(ColumnName = "JobNo")]        
        public string JobNo { get; set; }
        
        /// <summary>
        /// 姓名
        /// </summary>
        [SugarColumn(ColumnName = "ReallName")]        
        public string ReallName { get; set; }
        
        /// <summary>
        /// 部门Id
        /// </summary>
        [SugarColumn(ColumnName = "DepartId")]        
        public string DepartId { get; set; }
        
        /// <summary>
        /// 部门
        /// </summary>
        [SugarColumn(ColumnName = "DepartName")]        
        public string DepartName { get; set; }
        
        /// <summary>
        /// 本次消费额
        /// </summary>
        [SugarColumn(ColumnName = "TxnTotalAmt")]        
        public decimal TxnTotalAmt { get; set; }
        
        /// <summary>
        /// 个人账户消费额
        /// </summary>
        [SugarColumn(ColumnName = "AccConsAmt")]        
        public decimal AccConsAmt { get; set; }
        
        /// <summary>
        /// 个人账户消费前余额
        /// </summary>
        [SugarColumn(ColumnName = "AccBalBef")]        
        public decimal AccBalBef { get; set; }
        
        /// <summary>
        /// 个人账户消费后余额
        /// </summary>
        [SugarColumn(ColumnName = "AccBalAfter")]        
        public decimal AccBalAfter { get; set; }
        
        /// <summary>
        /// 福利账户消费额
        /// </summary>
        [SugarColumn(ColumnName = "WelfareConsAmt")]        
        public decimal WelfareConsAmt { get; set; }
        
        /// <summary>
        /// 福利账户消费前余额
        /// </summary>
        [SugarColumn(ColumnName = "WelfareBalBef")]        
        public decimal WelfareBalBef { get; set; }
        
        /// <summary>
        /// 福利账户消费后余额
        /// </summary>
        [SugarColumn(ColumnName = "WelfareBalAfter")]        
        public decimal WelfareBalAfter { get; set; }
        
        /// <summary>
        /// 交易流水号
        /// </summary>
        [SugarColumn(ColumnName = "TxnSeq")]        
        public string TxnSeq { get; set; }
        
        /// <summary>
        /// 交易时间
        /// </summary>
        [SugarColumn(ColumnName = "TxnDate")]        
        public DateTime? TxnDate { get; set; }
        
        /// <summary>
        /// 交易结果 1成功 0失败
        /// </summary>
        [SugarColumn(ColumnName = "TxnResult")]        
        public int TxnResult { get; set; }
        
        /// <summary>
        /// 
        /// </summary>
        [SugarColumn(ColumnName = "dbDate")]        
        public DateTime? DbDate { get; set; }
        
        /// <summary>
        /// 请求扣费流水Id
        /// </summary>
        [SugarColumn(ColumnName = "RequestId")]        
        public string RequestId { get; set; }
        
        /// <summary>
        /// 
        /// </summary>
        [SugarColumn(ColumnName = "SortCode")]        
        public long SortCode { get; set; }
        
        /// <summary>
        /// 
        /// </summary>
        [SugarColumn(ColumnName = "Summary")]        
        public string Summary { get; set; }
        
        /// <summary>
        /// 
        /// </summary>
        [SugarColumn(ColumnName = "IsAnaly")]        
        public int? IsAnaly { get; set; }
        
        /// <summary>
        /// 交易明细Id
        /// </summary>
        [SugarColumn(ColumnName = "DetailId")]        
        public string DetailId { get; set; }


        /// <summary>
        /// 上传时间
        /// </summary>
        [SugarColumn(ColumnName = "UploadTime")]
        public DateTime UploadTime { get; set; }
        /// <summary>
        /// 消费方式0在线 1离线
        /// </summary>
        [SugarColumn(ColumnName = "PayWay")]
        public int PayWay { get; set; }

        /// <summary>
        /// 所属公司Id
        /// </summary>
        [SugarColumn(ColumnName = "CompanyId")]
        public string CompanyId { get; set; }

        /// <summary>
        /// 公司名称
        /// </summary>
        [SugarColumn(ColumnName = "CompanyName")]
        public string CompanyName { get; set; }


        #region 调账信息
        /// <summary>
        /// 调账消费额
        /// </summary>
        [SugarColumn(ColumnName = "AdjustAmt")]
        public decimal AdjustAmt { get; set; }

        /// <summary>
        /// 个人账户消费额_调整后
        /// </summary>
        [SugarColumn(ColumnName = "AjtAccConsAmt")]
        public decimal AjtAccConsAmt { get; set; }

        /// <summary>
        /// 个人账户消费前余额_调整后
        /// </summary>
        [SugarColumn(ColumnName = "AjtAccBalBef")]
        public decimal AjtAccBalBef { get; set; }

        /// <summary>
        /// 个人账户消费后余额_调整后
        /// </summary>
        [SugarColumn(ColumnName = "AjtAccBalAfter")]
        public decimal AjtAccBalAfter { get; set; }

        /// <summary>
        /// 福利账户消费额_调整后
        /// </summary>
        [SugarColumn(ColumnName = "AjtWelfareConsAmt")]
        public decimal AjtWelfareConsAmt { get; set; }

        /// <summary>
        /// 福利账户消费前余额_调整后
        /// </summary>
        [SugarColumn(ColumnName = "AjtWelfareBalBef")]
        public decimal AjtWelfareBalBef { get; set; }

        /// <summary>
        /// 福利账户消费后余额_调整后
        /// </summary>
        [SugarColumn(ColumnName = "AjtWelfareBalAfter")]
        public decimal AjtWelfareBalAfter { get; set; }
        #endregion
    }
}